<?php
$insertvalue = array();
$insertvalue[projectname] = "addprojectname";
$insertvalue[projectvalue] = "addprojectvalue";
$insertvalue[projecttype] = "addprojecttype";
$insertvalue[projectdomain] = "addprojectdomain";
//print_r($insertvalue);
$field1 = "";
//$field2 = "";
$i=1;$count = count($insertvalue);
foreach($insertvalue as $key=>$value)
{
if($i==$count)
{
$field1.=$key."=".$value;
//$field2.=$value;
}
else
{
$field1.=$key."=".$value.",";
//$field2.=$value.",";
}
$i++;
}
echo $field1;

?>